﻿using System;
using SocketBook7Server.Script.net;
//partial 表明是局部类 允许将一个类 结构体 接口分成几个部分，分别实现在几个不同得.cs文件中
namespace SocketBook7Server.Script.logic
{
    public partial class MsgHandler
    {
        public static void MsgMove(ClientState c, MsgBase msgBase)
        {
            MsgMove msgMove = (MsgMove)msgBase;
            Console.WriteLine("MsgMove: " + msgMove.x);
            msgMove.x++;
            NetManager.Send(c, msgMove);
        }
        public static void MsgOnDisconnect(ClientState c, MsgBase msgBase)
        {
            Console.WriteLine("MsgOnDisconnect: " + c.socket.RemoteEndPoint.ToString());
            NetManager.Close(c);

        }
    }
}